package org.sagitta.httprpc.utils;


public class CommonUtil {

	/**
	 * Upper the first letter for a string
	 * 
	 * @param str
	 *            the target string
	 * @return String
	 */
	public static String upperFirstLetter(String str) {
		if (isNullString(str))
			return str;
		return str.substring(0, 1).toUpperCase() + str.substring(1, str.length());
	}

	/**
	 * determine a string is null or not null string
	 * 
	 * @param s
	 *            the target string
	 * @return true: has content, false: no content
	 */
	public static boolean isNullString(String s) {
		return s == null || "".equals(s);
	}

}
